#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
__title__ = ''
__author__ = 'wendy'
__mtime__ = '2017/3/5'
"""

import sys

sys.path.append('E:\wendygit\scalersForum\src\s126_wendy')

from src.s126_wendy.scalers.support import cookieUtil

def firstMethod():
    cookieStr = "pac_uid=1_790947589; tvfe_boss_uuid=7bb1f90025e2bbfe; gaduid=57d10cc1cda81; msuid=ix1eueb9rd7er3e8uuw57ubelrmwwgq2nlx2bfuj; o_cookie=790947589; pgv_pvid=9590355513; ptcz=4241e320be9ad14ac93cb42360544d4bdca22324388f785739209b450813a2b8; pt2gguin=o0790947589; uin=o0790947589; skey=@pmRxmLa2S; ptisp=ctc; MANYOU_SESSIONID_bf895=a1281c993501a9e4ccb644ca3c5bbbb1; qqUser=%7B%22uin%22%3A790947589%2C%22nic"
    cookieDic = cookieUtil.convertStrToDict(cookieStr)
    for item in cookieDic.keys():
        print("%s = %s" %(item, cookieDic[item]))

if __name__ == "__main__":
    print ("hello world")
    firstMethod()



"""
D:\Python34\python.exe E:/wendygit/scalersForum/src/s126_wendy/mainFetch.py
Traceback (most recent call last):
  File "E:/wendygit/scalersForum/src/s126_wendy/mainFetch.py", line 13, in <module>
    from .scalers.support import cookieUtil
SystemError: Parent module '' not loaded, cannot perform relative import

Process finished with exit code 1

网上搜到的结果：
I had the same problem and I solved it by using an absolute import instead of a relative one.
Note that relative imports are based on the name of the current module. Since the name of the main module is always "__main__",
modules intended for use as the main module of a Python application must always use absolute imports.
"""